# -----------------------------------------------
# Author: yuz
# Copyright: 柠檬班
# Email: wagyu2016@163.com
# Phone&Wechat: 18173179913
# -----------------------------------------------
from faker import Faker

fk = Faker(locale='zh_CN')

def generate_user():
    user = fk.profile(fields=['address', 'company', 'job', 'mail', 'name', 'sex', 'username'])
    return user


def generate_users(num):
    users = []
    for id in range(1, num+1):
        user = generate_user()
        user['id'] = id
        users.append(user)
    return users


if __name__ == '__main__':
    users = generate_users(100)
    import pprint
    pprint.pprint(users)

